package itheima.com.MyTree;

import java.text.Collator;
import java.util.Locale;
import java.util.TreeSet;

public class Demo01 {
    public static void main(String[] args) {
        Collator instance = Collator.getInstance(Locale.CHINA);
        TreeSet<String> set = new TreeSet<>(instance);
        set.add("张三");
        set.add("张三疯");
        set.add("王二狗");
        set.add("李皮皮");
        set.add("赵构");

        for (String s : set) {
            System.out.println(s);
        }
    }
}
